<template>

  <div id="app">

    <wii-second @click.native="nativeClick" @on-click-button="clickButton"></wii-second>

  </div>

</template>

 

<script>

import WiiSecond from '@/render/wii-secon'

 

export default {

  name: 'app',

  components: {

    WiiSecond

  },

  data() {

    return {

    }

  },

  methods: {

    nativeClick() {

      console.log('这是组件外部click.native触发的事件，第二个组件被点击了')

    },

    clickButton() {

      console.log('这是组件外部触发的【emit】事件，第二个组件被点击了')

    }

  }

}

</script>